﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Spun.Models.Sequences;

namespace Formality.Server
{
    public class MySequence<T> : Sequence<T>
    {
        public MySequence() : base(typeof(MySequence<T>), false, true) { }

        public override uint Count
        {
            get
            {
                return (uint)Array.Length;
            }
            set
            {
                throw new NotImplementedException();
            }
        }

        public override T this[uint Index]
        {
            get
            {
                return Array[Index];
            }
            set
            {
                throw new NotImplementedException();
            }
        }

        public override IEnumerator<T> GetEnumerator()
        {
            foreach (var i in Array)
                yield return i;
        }

        public void Update(IEnumerable<T> NewElements)
        {
            
        }

        private T[] Array;
    }
}
